import React, { Component } from 'react'
import UserList from './../../components/user-list/user-list'
import { connect } from 'react-redux'
import { getUserList } from './../../redux/action'
class Dashen extends Component {
  constructor(props) {
    super(props)
    this.state = {}
  }
  componentWillMount() {
    this.props.getUserList()
  }
  render() {
    return (
      <div>
        <UserList userList={this.props.userList} />
      </div>
    )
  }
}

export default connect(
  state => ({ userList: state.userList }),
  { getUserList }
)(Dashen)
